package com.mallplus.rbac.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.util.List;

/**
 * @author Hanson
 * @date 2023/4/15 18:58
 */
@Data
public class RouteMetaVO {

    @Schema(description = "设置该路由在侧边栏和面包屑中展示的名字" )
    private String title;

    @Schema(description = "设置该路由的图标，支持 svg-class，也支持 el-icon-x element-ui 的 icon" )
    private String icon;

    @Schema(description = "如果设置为true，则不会被 <keep-alive> 缓存(默认 false)" )
    private Boolean noCache;

    @Schema(description = "如果设置为false，则不会在breadcrumb面包屑中显示(默认 true)" )
    private Boolean breadcrumb;

    @Schema(description = "若果设置为true，它则会固定在tags-view中(默认 false)")
    private Boolean affix;

    @Schema(description = "当路由设置了该属性，则会高亮相对应的侧边栏。")
    private String activeMenu;

    @Schema(description = "需要什么权限才能访问该菜")
    private List<String> roles;

    @Override
    public String toString() {
        return "RouteMetaVo{" +
                "title=" + title + '\'' +
                ", icon=" + icon + '\'' +
                ", noCache=" + noCache +
                ", breadcrumb=" + breadcrumb +
                ", affix=" + affix +
                ", activeMenu=" + activeMenu + '\'' +
                ", roles=" + roles +
                "}";

    }
}
